﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Designpatterns
{
    public class Observer:IObserver
    {
        public string ObserverName 
        {   get; 
            private set; 
        }

        public Observer(string name)
        {
            this.ObserverName = name;
        }

        public void Update()
        {
            Console.WriteLine("{0}: A new product has arrived at the store", this.ObserverName);
        }
        
    }

    interface IObserver
    {
        void Update();
    }
}
